package com.java.demo.model;


import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;
/*
* 公共对象
* */

@Component
public class Users {
  @Bean("user")
  @Scope("prototype")
  public User getUser(){
      User user = new User();
      user.setId(123);
      user.setName("李逵");
      return user;
  }
}
